package com.platform.base.domain;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableField;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.platform.common.annotation.Excel;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import javax.validation.constraints.NotBlank;
import com.platform.common.core.domain.BaseEntity;

/**
 * 阀门信息对象 valve_info
 * 
 * @author wangqi
 * @date 2020-09-25
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("valve_info")
public class ValveInfo extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 阀门id */
    @TableId(type = IdType.INPUT)
    @Excel(name = "阀门id")
    private String valveId;

    /** 阀门型号 */
    private Long typeId;

    /** 安装地址 */
    private Long locationId;

    /** 采集器id */
    @NotBlank(message = "采集器ID不能为空")
    @Excel(name = "采集器id")
    private String collectorId;

    /** 安装时间 */
    @Excel(name = "安装时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date installTime;

    /** 登记状态（0未登记1已登记） */
    private String registerFlag;

    /** 阀门型号 */
    @TableField(exist = false)
    @Excel(name = "阀门型号", targetAttr = "typeName", type = Excel.Type.EXPORT)
    private ValveType type;

    /** 阀门位置 */
    @TableField(exist = false)
    @Excel(name = "阀门位置", targetAttr = "locationName", type = Excel.Type.EXPORT)
    private BaseLocation location;

    @TableField(exist = false)
    @Excel(name = "生产厂商", targetAttr = "factoryName", type = Excel.Type.EXPORT)
    private BaseFactory factory;

    @Excel(name = "阀门型号", type = Excel.Type.IMPORT)
    @TableField(exist = false)
    private String typeName;

    @Excel(name = "阀门位置", type = Excel.Type.IMPORT)
    @TableField(exist = false)
    private String locationName;

    @TableField(exist = false)
    private String valveIds;

    /** 阀门开度 */
    @TableField(exist = false)
    private int aperture;
    /** 阀门开度 */
    @TableField(exist = false)
    private int aperturemax;
    /** 阀门开度 */
    @TableField(exist = false)
    private int aperturemin;
    /** 阀门开度 */
    @TableField(exist = false)
    private String tempmax;

    /** 出水温度 */
    @TableField(exist = false)
    private int outlet;

    /** 阀门数量 */
    @TableField(exist = false)
    private int count;

    /** 上线状态 */
    private Integer onlineStatus;
}
